1. Field of the Invention
The present invention relates to the field of software testing. More specifically, the present invention relates to automatic generation of auauto-checking test functions.
2. Art Background
Traditionally, software testing was done on an ad-hoc basis. As the complexity of software increases with increasing function being offered, various approaches, techniques and tools have been developed to provide a more structured or disciplined approach to software testing. From a process perspective, typically a phase approach is used to divide software testing into different stages, such as requirement testing, design testing, unit testing, function testing, and system testing. For each stage, different testing techniques, such as boundary value testing and sampling, are applied to improve test coverages. Additionally, various testing tools, such as test case generators and simulators, are developed to improve testing efficiency.
Traditionally, software specification and design were also done on an informal basis. Similarly, as the complexity of software increases with increasing function being offered, various techniques and tools have been developed to provide a more formal approach to software specification and design. Particular examples of formal design techniques include top down design and data flow analysis. Particular examples of formal design tools include formal specification and design languages and various Computer Aided Software Engineering (CASE) tools.
The advent of formal specification and design languages offers a new opportunity for further imposing structure and discipline to software testing. The formal specifications can be submitted to machine based analysis. If the proper behavior of a software interface can be adequately described by its formal specification, then test functions can be automatically and systematically generated for the software interface from the formal specification. Furthermore, the generated test functions can be auto-checking. An auto-checking test function is a function that can invoke and execute a procedure to be tested and knows enough about the procedure to be able to determine whether the procedure behaved properly or improperly when the procedure was tested.
Thus, it is desirable to be able to formally specify the proper behavior of a software interface, automatically and systematically generate test functions for the software interface from its formal specification. It is further desirable that these generated test functions are auto-checking.
As will be disclosed, the present invention provides methods and apparatus for formally specifying software interfaces, automatically and systematically generating auto-checking test functions from these formal specifications, which achieves the desired results described above.